Skip to content
This repository has been archived by the owner on Oct 13, 2022. It is now read-only.

Constructing ctc decoding graph in a batch #225

Closed
wants to merge 2 commits into from

Conversation

pkufool
Copy link
Contributor

@pkufool pkufool commented Jul 1, 2021

See comments #220

Thanks for doing the comparison, and sure, that's a good idea. Yes, we should introduce a special-purpose function that constructs a batch of CTC graphs from a ragged tensor consisting of the linear symbol sequences for each one.

Current functions in k2 support to construct ctc decoding graph in a batch, so I think there is no other things should be done in C++ side. Fix me if I understand in a wrong way.

@danpovey
Copy link
Contributor

danpovey commented Jul 1, 2021

I think we were talking about doing it in a single function, rather than a sequence of functions.
BTW, we'd have to decide which type of topology to use, in terms of how it deals with repeats of the same
symbol (i.e. do we require a blank in between?). If we require a blank in between those repeats, the code
becomes a little more complicated.

@pkufool pkufool closed this Jul 1, 2021
@pkufool pkufool reopened this Jul 1, 2021
@pkufool
Copy link
Contributor Author

pkufool commented Jul 1, 2021

I see, so we will implement a function in k2 that given a lexicon fsa and ragged tensor consisting of the linear symbol sequences as input and return the ctc graph.

@danpovey
Copy link
Contributor

danpovey commented Jul 1, 2021

No, it would take just a sequence of phone symbols (or whatever symbols the user is using, not necessarily worsd),
and return the linear CTC graph; I think that is his scenario. This would not support optional silences.

@pkufool pkufool closed this Jul 9, 2021
@pkufool
Copy link
Contributor Author

pkufool commented Jul 9, 2021

Implements in the c++ side, see k2-fsa/k2#776

@pkufool pkufool deleted the ctc_graph branch July 9, 2021 01:05
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants